﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using clf.weighing.entity;

namespace weighing
{
    public class DelegeteFactory
    {
        private static DelegeteFactory _factory;
        public static DelegeteFactory Instance
        {
            get
            {
                if (_factory == null) _factory = new DelegeteFactory();
                return _factory;
            }
        }


        /// <summary>
        /// 设备数据有改变，有增删改 操作
        /// </summary>
        public Action DeviceDataChanged;


     
        /// <summary>
        /// 当 称重配制 改变
        /// </summary>
        public Action<WeighingConfig> OnWeighingConfigChanged;

        /// <summary>
        /// 当收发货地址增加
        /// </summary>
        public Action<Yard> OnYardAdd;

        /// <summary>
        /// 当收发货地址修改
        /// </summary>
        public Action<Yard> OnYardUpdate;


        /// <summary>
        /// 当默认磅房修改
        /// </summary>
        public Action<ScaleHouseVo> OnDefaultScaleHouseChanged;

        /// <summary>
        /// 当磅单设置被修改
        /// </summary>
        public Action OnBillSettingChanged;

  

        public Action<BackupBillField> OnBackupBillFieldChanged;


        /// <summary>
        /// 当 称重模式改变
        /// </summary>
        public Action<WeighingMode> OnWeighingWeighingModeChanged;

        /// <summary>
        /// 当 有磅单改变
        /// </summary>
        public Action<WeightingBillType> onWeighingDataChanged;


        /// <summary>
        /// 当简易过磅时，双击要出场的过磅数据
        /// </summary>
        public Action<WeighingBill> onSimpleWeighingSelectOutData;


        /// <summary>
        /// 当使用单单位改变时
        /// </summary>
        public Action<CompanyVo> onUserCompanyChanged;

    }
}
